<?php

namespace App\Recharge\Enums;

enum RechargeStatusEnum: int
{
    /**
     * 充值中
     */
    case Recharging = 0;

    /**
     * 充值成功
     */
    case RechargeSuccess = 1;

    /**
     * 充值失败
     */
    case RechargeError = 2;

    /**
     * @return string
     */
    public function statusText(): string
    {
        return match ($this) {
            self::RechargeSuccess => '充值成功',
            self::RechargeError => '充值失败',
            default => '充值中',
        };
    }
}
